<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.17"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Jetson Inference: commandLine Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="NVLogo_2D.jpg"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Jetson Inference
   </div>
   <div id="projectbrief">DNN Vision Library</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.17 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('classcommandLine.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pub-attribs">Public Attributes</a> &#124;
<a href="classcommandLine-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">commandLine Class Reference<div class="ingroups"><a class="el" href="group__util.html">Utilities Library (jetson-utils)</a> &raquo; <a class="el" href="group__commandLine.html">Command-Line Parsing</a></div></div>  </div>
</div><!--header-->
<div class="contents">

<p>Command line parser for extracting flags, values, and strings.  
 <a href="classcommandLine.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="commandLine_8h_source.html">commandLine.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a3e9685cf096fe039982b2749b2fd37b7"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#a3e9685cf096fe039982b2749b2fd37b7">commandLine</a> (const int <a class="el" href="classcommandLine.html#a7e44bdf5e5dcafee061bd3827002117a">argc</a>, char **<a class="el" href="classcommandLine.html#adb4c762405ba4b6bb81d99daa85f98bf">argv</a>, const char *extraFlag=NULL)</td></tr>
<tr class="memdesc:a3e9685cf096fe039982b2749b2fd37b7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor, takes the command line from <code>main()</code>  <a href="classcommandLine.html#a3e9685cf096fe039982b2749b2fd37b7">More...</a><br /></td></tr>
<tr class="separator:a3e9685cf096fe039982b2749b2fd37b7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a446633b337ea11f5ad79b38c45894cd7"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#a446633b337ea11f5ad79b38c45894cd7">commandLine</a> (const int <a class="el" href="classcommandLine.html#a7e44bdf5e5dcafee061bd3827002117a">argc</a>, char **<a class="el" href="classcommandLine.html#adb4c762405ba4b6bb81d99daa85f98bf">argv</a>, const char **extraArgs)</td></tr>
<tr class="memdesc:a446633b337ea11f5ad79b38c45894cd7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor, takes the command line from <code>main()</code>  <a href="classcommandLine.html#a446633b337ea11f5ad79b38c45894cd7">More...</a><br /></td></tr>
<tr class="separator:a446633b337ea11f5ad79b38c45894cd7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae8264c15d7154918323bb14ded89565b"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#ae8264c15d7154918323bb14ded89565b">GetFlag</a> (const char *argName, bool allowOtherDelimiters=true) const</td></tr>
<tr class="memdesc:ae8264c15d7154918323bb14ded89565b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks to see whether the specified flag was included on the command line.  <a href="classcommandLine.html#ae8264c15d7154918323bb14ded89565b">More...</a><br /></td></tr>
<tr class="separator:ae8264c15d7154918323bb14ded89565b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7ca2a1cb2c4f8f835c8ce0c89ccb92d8"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#a7ca2a1cb2c4f8f835c8ce0c89ccb92d8">GetFloat</a> (const char *argName, float defaultValue=0.0f, bool allowOtherDelimiters=true) const</td></tr>
<tr class="memdesc:a7ca2a1cb2c4f8f835c8ce0c89ccb92d8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get float argument.  <a href="classcommandLine.html#a7ca2a1cb2c4f8f835c8ce0c89ccb92d8">More...</a><br /></td></tr>
<tr class="separator:a7ca2a1cb2c4f8f835c8ce0c89ccb92d8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a82502d6930cc10b5147ab32ec412c996"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#a82502d6930cc10b5147ab32ec412c996">GetInt</a> (const char *argName, int defaultValue=0, bool allowOtherDelimiters=true) const</td></tr>
<tr class="memdesc:a82502d6930cc10b5147ab32ec412c996"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get integer argument.  <a href="classcommandLine.html#a82502d6930cc10b5147ab32ec412c996">More...</a><br /></td></tr>
<tr class="separator:a82502d6930cc10b5147ab32ec412c996"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa9604b3b315b3a62177d6f920fb6bec9"><td class="memItemLeft" align="right" valign="top">uint32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#aa9604b3b315b3a62177d6f920fb6bec9">GetUnsignedInt</a> (const char *argName, uint32_t defaultValue=0, bool allowOtherDelimiters=true) const</td></tr>
<tr class="memdesc:aa9604b3b315b3a62177d6f920fb6bec9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get unsigned integer argument.  <a href="classcommandLine.html#aa9604b3b315b3a62177d6f920fb6bec9">More...</a><br /></td></tr>
<tr class="separator:aa9604b3b315b3a62177d6f920fb6bec9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a79b0fc5258dbd12ba4b0cb5df77d424c"><td class="memItemLeft" align="right" valign="top">const char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#a79b0fc5258dbd12ba4b0cb5df77d424c">GetString</a> (const char *argName, const char *defaultValue=NULL, bool allowOtherDelimiters=true) const</td></tr>
<tr class="memdesc:a79b0fc5258dbd12ba4b0cb5df77d424c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get string argument.  <a href="classcommandLine.html#a79b0fc5258dbd12ba4b0cb5df77d424c">More...</a><br /></td></tr>
<tr class="separator:a79b0fc5258dbd12ba4b0cb5df77d424c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab5de00debc91a7ef79014a301a9b4a9f"><td class="memItemLeft" align="right" valign="top">const char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#ab5de00debc91a7ef79014a301a9b4a9f">GetPosition</a> (unsigned int position, const char *defaultValue=NULL) const</td></tr>
<tr class="memdesc:ab5de00debc91a7ef79014a301a9b4a9f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get positional string argument.  <a href="classcommandLine.html#ab5de00debc91a7ef79014a301a9b4a9f">More...</a><br /></td></tr>
<tr class="separator:ab5de00debc91a7ef79014a301a9b4a9f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abfb9272579250ddfde6f817417d0a7d8"><td class="memItemLeft" align="right" valign="top">unsigned int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#abfb9272579250ddfde6f817417d0a7d8">GetPositionArgs</a> () const</td></tr>
<tr class="memdesc:abfb9272579250ddfde6f817417d0a7d8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the number of positional arguments in the command line.  <a href="classcommandLine.html#abfb9272579250ddfde6f817417d0a7d8">More...</a><br /></td></tr>
<tr class="separator:abfb9272579250ddfde6f817417d0a7d8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae29c5133c330e73b98babdf7d6b0a1a0"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#ae29c5133c330e73b98babdf7d6b0a1a0">AddArg</a> (const char *arg)</td></tr>
<tr class="memdesc:ae29c5133c330e73b98babdf7d6b0a1a0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Add an argument to the command line.  <a href="classcommandLine.html#ae29c5133c330e73b98babdf7d6b0a1a0">More...</a><br /></td></tr>
<tr class="separator:ae29c5133c330e73b98babdf7d6b0a1a0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7acf24df58355c7deda8a74cc6bf8048"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#a7acf24df58355c7deda8a74cc6bf8048">AddArgs</a> (const char **args)</td></tr>
<tr class="memdesc:a7acf24df58355c7deda8a74cc6bf8048"><td class="mdescLeft">&#160;</td><td class="mdescRight">Add arguments to the command line.  <a href="classcommandLine.html#a7acf24df58355c7deda8a74cc6bf8048">More...</a><br /></td></tr>
<tr class="separator:a7acf24df58355c7deda8a74cc6bf8048"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae7c08e1e2d3a5f98ee12c93a7dfb3ad2"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#ae7c08e1e2d3a5f98ee12c93a7dfb3ad2">AddFlag</a> (const char *flag)</td></tr>
<tr class="memdesc:ae7c08e1e2d3a5f98ee12c93a7dfb3ad2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Add a flag to the command line.  <a href="classcommandLine.html#ae7c08e1e2d3a5f98ee12c93a7dfb3ad2">More...</a><br /></td></tr>
<tr class="separator:ae7c08e1e2d3a5f98ee12c93a7dfb3ad2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8fcd1c842318a965f2a194a72fb3083e"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#a8fcd1c842318a965f2a194a72fb3083e">Print</a> () const</td></tr>
<tr class="memdesc:a8fcd1c842318a965f2a194a72fb3083e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Print out the command line for reference.  <a href="classcommandLine.html#a8fcd1c842318a965f2a194a72fb3083e">More...</a><br /></td></tr>
<tr class="separator:a8fcd1c842318a965f2a194a72fb3083e"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-attribs"></a>
Public Attributes</h2></td></tr>
<tr class="memitem:a7e44bdf5e5dcafee061bd3827002117a"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#a7e44bdf5e5dcafee061bd3827002117a">argc</a></td></tr>
<tr class="memdesc:a7e44bdf5e5dcafee061bd3827002117a"><td class="mdescLeft">&#160;</td><td class="mdescRight">The argument count that the object was created with from main()  <a href="classcommandLine.html#a7e44bdf5e5dcafee061bd3827002117a">More...</a><br /></td></tr>
<tr class="separator:a7e44bdf5e5dcafee061bd3827002117a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adb4c762405ba4b6bb81d99daa85f98bf"><td class="memItemLeft" align="right" valign="top">char **&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcommandLine.html#adb4c762405ba4b6bb81d99daa85f98bf">argv</a></td></tr>
<tr class="memdesc:adb4c762405ba4b6bb81d99daa85f98bf"><td class="mdescLeft">&#160;</td><td class="mdescRight">The argument strings that the object was created with from main()  <a href="classcommandLine.html#adb4c762405ba4b6bb81d99daa85f98bf">More...</a><br /></td></tr>
<tr class="separator:adb4c762405ba4b6bb81d99daa85f98bf"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Command line parser for extracting flags, values, and strings. </p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="a3e9685cf096fe039982b2749b2fd37b7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3e9685cf096fe039982b2749b2fd37b7">&#9670;&nbsp;</a></span>commandLine() <span class="overload">[1/2]</span></h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">commandLine::commandLine </td>
          <td>(</td>
          <td class="paramtype">const int&#160;</td>
          <td class="paramname"><em>argc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char **&#160;</td>
          <td class="paramname"><em>argv</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>extraFlag</em> = <code>NULL</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Constructor, takes the command line from <code>main()</code> </p>

</div>
</div>
<a id="a446633b337ea11f5ad79b38c45894cd7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a446633b337ea11f5ad79b38c45894cd7">&#9670;&nbsp;</a></span>commandLine() <span class="overload">[2/2]</span></h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">commandLine::commandLine </td>
          <td>(</td>
          <td class="paramtype">const int&#160;</td>
          <td class="paramname"><em>argc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char **&#160;</td>
          <td class="paramname"><em>argv</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char **&#160;</td>
          <td class="paramname"><em>extraArgs</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Constructor, takes the command line from <code>main()</code> </p>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="ae29c5133c330e73b98babdf7d6b0a1a0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae29c5133c330e73b98babdf7d6b0a1a0">&#9670;&nbsp;</a></span>AddArg()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void commandLine::AddArg </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>arg</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Add an argument to the command line. </p>

</div>
</div>
<a id="a7acf24df58355c7deda8a74cc6bf8048"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7acf24df58355c7deda8a74cc6bf8048">&#9670;&nbsp;</a></span>AddArgs()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void commandLine::AddArgs </td>
          <td>(</td>
          <td class="paramtype">const char **&#160;</td>
          <td class="paramname"><em>args</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Add arguments to the command line. </p>

</div>
</div>
<a id="ae7c08e1e2d3a5f98ee12c93a7dfb3ad2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae7c08e1e2d3a5f98ee12c93a7dfb3ad2">&#9670;&nbsp;</a></span>AddFlag()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void commandLine::AddFlag </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>flag</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Add a flag to the command line. </p>

</div>
</div>
<a id="ae8264c15d7154918323bb14ded89565b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae8264c15d7154918323bb14ded89565b">&#9670;&nbsp;</a></span>GetFlag()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool commandLine::GetFlag </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>argName</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>allowOtherDelimiters</em> = <code>true</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Checks to see whether the specified flag was included on the command line. </p>
<p>For example, if argv contained <code>--foo</code>, then <code>GetFlag("foo")</code> would return <code>true</code></p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">allowOtherDelimiters</td><td>if true (default), the argName will be matched against occurances containing either <code>-</code> or <code>_</code>. <br  />
 For example, <code>--foo-bar</code> and <code>--foo_bar</code> would be the same.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>true</code>, if the flag with argName was found <code>false</code>, if the flag with argName was not found </dd></dl>

</div>
</div>
<a id="a7ca2a1cb2c4f8f835c8ce0c89ccb92d8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7ca2a1cb2c4f8f835c8ce0c89ccb92d8">&#9670;&nbsp;</a></span>GetFloat()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">float commandLine::GetFloat </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>argName</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float&#160;</td>
          <td class="paramname"><em>defaultValue</em> = <code>0.0f</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>allowOtherDelimiters</em> = <code>true</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get float argument. </p>
<p>For example if argv contained <code>--foo=3.14159</code>, then <code>GetInt("foo")</code> would return <code>3.14159f</code></p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">allowOtherDelimiters</td><td>if true (default), the argName will be matched against occurances containing either <code>-</code> or <code>_</code>. <br  />
 For example, <code>--foo-bar</code> and <code>--foo_bar</code> would be the same.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>defaultValue</code> if the argument couldn't be found. (<code>0.0</code> by default). Otherwise, returns the value of the argument. </dd></dl>

</div>
</div>
<a id="a82502d6930cc10b5147ab32ec412c996"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a82502d6930cc10b5147ab32ec412c996">&#9670;&nbsp;</a></span>GetInt()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int commandLine::GetInt </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>argName</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>defaultValue</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>allowOtherDelimiters</em> = <code>true</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get integer argument. </p>
<p>For example if argv contained <code>--foo=100</code>, then <code>GetInt("foo")</code> would return <code>100</code></p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">allowOtherDelimiters</td><td>if true (default), the argName will be matched against occurances containing either <code>-</code> or <code>_</code>. <br  />
 For example, <code>--foo-bar</code> and <code>--foo_bar</code> would be the same.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>defaultValue</code> if the argument couldn't be found (<code>0</code> by default). Otherwise, returns the value of the argument. </dd></dl>

</div>
</div>
<a id="ab5de00debc91a7ef79014a301a9b4a9f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab5de00debc91a7ef79014a301a9b4a9f">&#9670;&nbsp;</a></span>GetPosition()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const char* commandLine::GetPosition </td>
          <td>(</td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>position</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>defaultValue</em> = <code>NULL</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get positional string argument. </p>
<p>Positional arguments aren't named, but rather referenced by their index in the list. For example if the command line contained <code>my-program --foo=bar /path/to/my_file.txt</code>, then <code>GetString(0)</code> would return `"/path/to/my_file.txt"</p>
<dl class="section return"><dt>Returns</dt><dd><code>defaultValue</code> if the argument couldn't be found (<code>NULL</code> by default). Otherwise, returns a pointer to the argument value string from the <code>argv</code> array. </dd></dl>

</div>
</div>
<a id="abfb9272579250ddfde6f817417d0a7d8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#abfb9272579250ddfde6f817417d0a7d8">&#9670;&nbsp;</a></span>GetPositionArgs()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">unsigned int commandLine::GetPositionArgs </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get the number of positional arguments in the command line. </p>
<p>Positional arguments are those that don't have a name. </p>

</div>
</div>
<a id="a79b0fc5258dbd12ba4b0cb5df77d424c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a79b0fc5258dbd12ba4b0cb5df77d424c">&#9670;&nbsp;</a></span>GetString()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const char* commandLine::GetString </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>argName</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>defaultValue</em> = <code>NULL</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>allowOtherDelimiters</em> = <code>true</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get string argument. </p>
<p>For example if argv contained <code>--foo=bar</code>, then <code>GetString("foo")</code> would return <code>"bar"</code></p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">allowOtherDelimiters</td><td>if true (default), the argName will be matched against occurances containing either <code>-</code> or <code>_</code>. <br  />
 For example, <code>--foo-bar</code> and <code>--foo_bar</code> would be the same.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>defaultValue</code> if the argument couldn't be found (<code>NULL</code> by default). Otherwise, returns a pointer to the argument value string from the <code>argv</code> array. </dd></dl>

</div>
</div>
<a id="aa9604b3b315b3a62177d6f920fb6bec9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa9604b3b315b3a62177d6f920fb6bec9">&#9670;&nbsp;</a></span>GetUnsignedInt()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">uint32_t commandLine::GetUnsignedInt </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>argName</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>defaultValue</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>allowOtherDelimiters</em> = <code>true</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Get unsigned integer argument. </p>
<p>For example if argv contained <code>--foo=100</code>, then <code>GetUnsignedInt("foo")</code> would return <code>100</code></p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">allowOtherDelimiters</td><td>if true (default), the argName will be matched against occurances containing either <code>-</code> or <code>_</code>. <br  />
 For example, <code>--foo-bar</code> and <code>--foo_bar</code> would be the same.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>defaultValue</code> if the argument couldn't be found, or if the value was negative (<code>0</code> by default). Otherwise, returns the parsed value. </dd></dl>

</div>
</div>
<a id="a8fcd1c842318a965f2a194a72fb3083e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8fcd1c842318a965f2a194a72fb3083e">&#9670;&nbsp;</a></span>Print()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void commandLine::Print </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Print out the command line for reference. </p>

</div>
</div>
<h2 class="groupheader">Member Data Documentation</h2>
<a id="a7e44bdf5e5dcafee061bd3827002117a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7e44bdf5e5dcafee061bd3827002117a">&#9670;&nbsp;</a></span>argc</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int commandLine::argc</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>The argument count that the object was created with from main() </p>

</div>
</div>
<a id="adb4c762405ba4b6bb81d99daa85f98bf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#adb4c762405ba4b6bb81d99daa85f98bf">&#9670;&nbsp;</a></span>argv</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char** commandLine::argv</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>The argument strings that the object was created with from main() </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>jetson-utils/<a class="el" href="commandLine_8h_source.html">commandLine.h</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="classcommandLine.html">commandLine</a></li>
    <li class="footer">Generated on Fri Mar 17 2023 14:29:30 for Jetson Inference by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.17 </li>
  </ul>
</div>
</body>
</html>
